package com.sitech.portal.server.dao;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.sitech.ibnms.core.IPage;
import com.sitech.ibnms.core.PageForm;

public interface IPortalDao {

	public List findAllPorlets();
	
	/**
	 * 获取用户所有角色下的porlet
	 * @param login_id
	 * @return
	 */
	public List findUserPorlets(String login_id);
	
	public void insertUserSetting(HashMap map);
	
	public IPage findAllPorletsList(PageForm pageForm);

    public Map findPorletById(String porlet_id);

    public void insertPORLET(Map porlet);

    public void updatePORLET(Map porlet);

    public void deletePORLETById(String porlet_id);

    public List findAllLayouts();

    public Map findLayoutById(String layout_id);

    public List findPorletsByROLE_ID(List<Map> ROLE_IDs);

    public Map findUserSetting(String LOGIN_ID);

    public int updateUserSetting_PORLETS(String LOGIN_ID, String PORLETS);

    public int updateUserSetting_LAYOUT(String LOGIN_ID, String LAYOUT_ID);

    public void updateRoleMapOfPorlet(String PORLET_ID, String[] ROLE_ID);

    public void insertRoleMapOfPorlet(String PORLET_ID, String ROLE_ID);

    public void deleteRoleMapOfPorlet(String PORLET_ID);
    
    public String findPortalHelper(String helpId);
    
    public void savePortalHelper(String helpId , String helpMsg);
    
    public boolean updatePortalHelper(String helpId , String helpMsg);
    
    /**
     * 获取用户个性化配置的porlet
     * @param userId
     * @return
     */
    public List findUserSettingPorlets(String userId);
}
